From 97e34120fef1967b127046639498843df163ee3e Mon Sep 17 00:00:00 2001 From: "kfraser@localhost.localdomain" Date: Fri, 20 Oct 2006 09:24:26 +0100 Subject: [PATCH] [BLKTAP]: Kill bogus fast_flush_area The function dispatch_rw_block_io may call fast_flush_area even before a pending request has been initialised. This patch deletes that call. Signed-off-by: Herbert Xu --- linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c b/linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c index a7e5037d72..0adaa7b5d8 100644 --- a/linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c +++ b/linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c @@ -1128,9 +1128,10 @@ static void dispatch_rw_block_io(blkif_t *blkif, int usr_idx = GET_NEXT_REQ(info->idx_map); uint16_t mmap_idx = pending_req->mem_idx; - /*Check we have space on user ring - should never fail*/ - if(usr_idx == INVALID_REQ) goto fail_flush; - + /* Check we have space on user ring - should never fail. */ + if (usr_idx == INVALID_REQ) + goto fail_response; + /* Check that number of segments is sane. */ nseg = req->nr_segments; if ( unlikely(nseg == 0) || -- 2.30.2